package com.stu.thread._01_create3ways._02_runnable;

public class Main {
  public static void main(String[] args) {
    Runnable r1 = new MyThread01();
    Thread t1 = new Thread(r1, "线程一");
    Thread t2 = new Thread(() -> {
      for (int i = 0; i < 10; i++) {
        System.out.println(Thread.currentThread().getName() + "：" + i);
      }
    }, "          线程二");
    t1.start();
    t2.start();
  }
}
